package org.objective.dal.commands;

import org.common.service.ServiceRegister;
import org.objective.command.AuthToken;
import org.objective.command.Command;
import org.objective.command.CommandResult;
import org.objective.dal.BeanFactory;
import org.objective.dal.RowValueCollection;
import org.objective.service.DalService;

/**
 *
 * @author gus
 */
public class GetRowValueCollectionCommand implements Command<RowValueCollection>
{
    private static final long serialVersionUID = 7421938569171751984L;
    private long[] objectIDs;
    private Class templateType;

    public GetRowValueCollectionCommand(long[] objectIDs, Class templateType)
    {
        this.objectIDs = objectIDs;
        this.templateType = templateType;
    }

    @Override
    public Object[] getParameters()
    {
        return new Object[]
            {
                objectIDs, templateType
            };
    }

    @Override
    public CommandResult<RowValueCollection> execute(ServiceRegister provider, AuthToken token) throws Exception
    {
        DalService dalService = provider.getService(DalService.class);
//        return dalService.getRowValueCollection(objectIDs, new BeanFactory(templateType));
        return null;
    }
}
